package sfy.md.behavior.observer;

public class Client {
    public static void main(String[] args){
        People people = new People();
        people.setAge("28");
        people.setName("sfy");

        Observer observerOne = new PeopleObserverOne();
        Observer observerTwo = new PeopleObserverTwo();
        people.add(observerOne);
        people.add(observerTwo);

        /**此方法调用了通知*/
        people.changeAge();

    }
}
